﻿<%@ Page Title="Marketing - View Summary" Language="C#" MasterPageFile="~/NPS/app/Marketing/marketing.master"
    AutoEventWireup="true" CodeFile="ViewSummary.aspx.cs" Inherits="NPS_app_Marketing_ViewSummary" %>

<%@ Register Assembly="DevExpress.Web.v9.2, Version=9.2.9.0, Culture=neutral, PublicKeyToken=b88d1754d700e49a"
    Namespace="DevExpress.Web.ASPxCallback" TagPrefix="dxcb" %>
<%@ Register Assembly="DevExpress.Web.ASPxGridView.v9.2, Version=9.2.9.0, Culture=neutral, PublicKeyToken=b88d1754d700e49a"
    Namespace="DevExpress.Web.ASPxGridView" TagPrefix="dxwgv" %>
<%@ Register Assembly="DevExpress.Web.ASPxEditors.v9.2" Namespace="DevExpress.Web.ASPxEditors"
    TagPrefix="dxe" %>
<%@ Register Assembly="DevExpress.Web.ASPxGridView.v9.2" Namespace="DevExpress.Web.ASPxGridView"
    TagPrefix="dxwgv" %>
<%@ Register Assembly="eWorld.UI, Version=2.0.1.2222, Culture=neutral, PublicKeyToken=24d65337282035f2"
    Namespace="eWorld.UI" TagPrefix="ew" %>
    
<asp:Content ContentPlaceHolderID="Back" runat="server">

    <a class="backbutton" href="../../Default.aspx" data-bind="click: closeApp">
        <img src="../../img/Left.png" />
    </a>
</asp:Content>
<asp:Content ContentPlaceHolderID="Header" runat="server">
    Marketing: View Summary
</asp:Content>
<asp:Content ContentPlaceHolderID="body" runat="server">

    <div id="body">
        <div class="container metro">
        
            <form runat="server" class="metro-form" id="Marketing">
            <asp:ScriptManager ID="ScriptManager1" runat="server" EnablePartialRendering="true"
                AsyncPostBackTimeout="7200" ScriptMode="Auto">
            </asp:ScriptManager>
            <asp:UpdatePanel ID="upHeader" runat="server" UpdateMode="Conditional">
                <ContentTemplate>
                    <fieldset title="View Summary">
                        <table style="width: 100%;" class="metro-form-control">
                            <tr>
                                <td style="width: 200px;">
                                    Marketing Type
                                </td>
                                <td class="style1">
                                    <div class="metro-text-box">
                                        <asp:DropDownList ID="ddlMarketingType" runat="server" DataTextField="sxTitle" DataValueField="iID"
                                            Width="300px" />
                                    </div>
                                </td>
                                <td rowspan="4" valign="bottom">
                                    <asp:Button ID="btnSearch" runat="server" CssClass="metro-button" Text="Search" OnClick="btnSearch_Click" />
                                </td>
                            </tr>
                            <tr>
                                <td>
                                    Marketing Name
                                </td>
                                <td class="style1">
                                    <div class="metro-text-box">
                                        <asp:DropDownList ID="ddlMarketingName" runat="server" DataTextField="sxTitle" DataValueField="iID"
                                            Width="300px" />
                                    </div>
                                </td>
                                </td>
                            </tr>
                            <tr>
                                <td>
                                    Start Date
                                </td>
                                <td class="style1">
                                    <div class="metro-text-box">
                                        <ew:CalendarPopup ID="txtStartDate" runat="server" Culture="Indonesian (Indonesia)"
                                            DisableTextBoxEntry="False" DisplayPrevNextYearSelection="True" Font-Size="X-Small"
                                            PadSingleDigits="True" PopupLocation="Right" ShowGoToToday="True" UpperBoundDate="9999-12-31"
                                            Width="80px">
                                            <ButtonStyle Font-Size="0" CssClass="metro-button-srch" Height="30px" />
                                            <TextBoxLabelStyle Height="16px" />
                                        </ew:CalendarPopup>
                                    </div>
                                </td>
                            </tr>
                            <tr>
                                <td>
                                    End Date
                                </td>
                                <td class="style1">
                                    <div class="metro-text-box">
                                        <ew:CalendarPopup ID="txtEndDate" runat="server" Culture="Indonesian (Indonesia)"
                                            DisableTextBoxEntry="False" DisplayPrevNextYearSelection="True" Font-Size="X-Small"
                                            PadSingleDigits="True" PopupLocation="Right" ShowGoToToday="True" UpperBoundDate="9999-12-31"
                                            Width="80px">
                                            <ButtonStyle Font-Size="0" CssClass="metro-button-srch" Height="30px" />
                                            <TextBoxLabelStyle Height="16px" />
                                        </ew:CalendarPopup>
                                    </div>
                                </td>
                            </tr>
                        </table>
                        <dxwgv:ASPxGridView ID="dgMarketing" KeyFieldName="iID" ClientInstanceName="dgMarketing_c"
                            runat="server" AutoGenerateColumns="false" Font-Size="Small" OnCustomCallback="dgMarketing_CustomCallback"
                            ForeColor="Black" Settings-ShowTitlePanel="true" Width="100%" Styles-GroupFooter-HorizontalAlign="Right"
                            
                            >
                            <Styles Header-HorizontalAlign="Center" AlternatingRow-Enabled="True" Cell-Wrap="true"
                                Cell-Font-Size="Smaller" Header-Wrap="true" Header-Font-Size="Smaller" Header-Font-Bold="true"
                                Cell-ForeColor="Black" >
                                <Header Wrap="True" Font-Size="Smaller" Font-Bold="True" ForeColor="Black">
                                </Header>
                                <AlternatingRow Enabled="True">
                                </AlternatingRow>
                                <Cell Wrap="True" Font-Size="Small">
                                </Cell>
                                <GroupPanel ForeColor="Black" />
                                <GroupRow ForeColor="Black" />
                            </Styles>
                            <Templates>
                                <TitlePanel>
                                    Marketing Summary
                                </TitlePanel>
                    
                            </Templates>
                            
                            <SettingsPager PageSize="10">
                            </SettingsPager>
                            <Settings ShowFilterBar="Visible" ShowFilterRow="true" ShowFilterRowMenu="true" ShowGroupedColumns="true"
                                ShowGroupButtons="true" ShowGroupFooter="VisibleAlways" />
                            <SettingsBehavior AllowSort="true" AllowGroup="true" AutoExpandAllGroups="true" />
                            <%--<ClientSideEvents EndCallback="dgMarketing_c_EndCallBack" />--%>
                            <Columns>
                                <dxwgv:GridViewDataTextColumn FieldName="oNPSMarketingName.sxTitle" Name="oNPSMarketingName.sxTitle"
                                    Caption="Marketing Name">
                                </dxwgv:GridViewDataTextColumn>
                                <dxwgv:GridViewDataTextColumn FieldName="sxTitle" Name="sxTitle" Caption="Title">
                                </dxwgv:GridViewDataTextColumn>
                                <dxwgv:GridViewDataTextColumn FieldName="sxLocation" Name="sxLocation" Caption="Location">
                                </dxwgv:GridViewDataTextColumn>
                                <dxwgv:GridViewDataDateColumn FieldName="dtmActivityDate" Name="dtmActivityDate" 
                                    Caption="Date">
                                </dxwgv:GridViewDataDateColumn>
                            </Columns>
                            
                            <GroupSummary>
                            
                                <dxwgv:ASPxSummaryItem  FieldName="sxTitle"  ShowInGroupFooterColumn="dtmActivityDate" SummaryType="Count" DisplayFormat="n0"  />
                            </GroupSummary>
                            <Settings ShowFooter="True" />
                        </dxwgv:ASPxGridView>
                    </fieldset>
                    <dxcb:ASPxCallback ID="cbkMarketing" ClientInstanceName="cbkMarketing_c" runat="server"
                        OnCallback="cbkMarketing_Callback">
                        <ClientSideEvents CallbackComplete="function(s, e) { cbkMarketing_c_CallbackComplete(e); }" />
                    </dxcb:ASPxCallback>
                </ContentTemplate>
            </asp:UpdatePanel>
            </form>
        </div>
    </div>
</asp:Content>
<asp:Content ID="Content1" runat="server" ContentPlaceHolderID="head">
    <style type="text/css">
        .style1
        {
            width: 312px;
        }
    </style>
</asp:Content>
